package view.login;

import oracle.adf.view.rich.component.rich.input.RichInputText;

public class Login {
    private RichInputText userName;
    private RichInputText password;

    public Login() {
        super();
    }
    
    public String validateUser(){
        String uName=(String)userName.getValue();
        String pwd=(String)password.getValue();
        if(uName.equals("siva") && pwd.equals("siva")) return "success";
        else if(uName.equals("rama") && pwd.equals("rama")) return "success";
        else return "fail";
    }

    public void setUserName(RichInputText userName) {
        this.userName = userName;
    }

    public RichInputText getUserName() {
        return userName;
    }

    public void setPassword(RichInputText password) {
        this.password = password;
    }

    public RichInputText getPassword() {
        return password;
    }
}
